<script setup>
import School from './components/School.vue';
</script>

<template>
 <div>
    <h1 ref="title">欢迎来学习</h1>
    <button @click="getDOM">获取欢迎信息的DOM</button>
  <School />
 </div>
</template>

<script>
export default {
    methods:{
        getDOM() {
            console.log(this.$refs.title);
        }
    }
}
</script>

<style scoped>

</style>
